package org.example.model;

import lombok.Data;
import org.springframework.data.mongodb.core.mapping.Document;
import java.util.Date;

@Data
@Document(collection = "chat_messages")
public class ChatMessage {
    private String type;        // 消息类型：CHAT, SYSTEM
    private String content;     // 消息内容
    private String fromId;      // 发送者ID
    private String fromName;    // 发送者名称
    private String toId;        // 接收者ID
    private Long timestamp;     // 时间戳
    private boolean fromCustomerService;  // 是否来自客服
    private boolean fromSystem;
    private Date createdAt;     // 创建时间
}